import time
import openpyxl

from domain.cellMap import get_dict

if __name__ == '__main__':
    # 获取列下标字典
    index_dict = get_dict('./列标记.xlsx', 'Sheet1')
    # 打开工作簿
    wb = openpyxl.load_workbook('基站级指标统计.xlsx', read_only=True)
    # 获取工作表
    ws = wb['Sheet1']
    # 时间
    old_time = time.time()

    i = 0
    print(index_dict)
    for row in ws.rows:
        if i < 1:
            i = 2
            continue
        print(row[0].value, row[1].value, row[2].value)

        # 中断循环
        if i == 5:
            break
        i += 1

    print(f'总耗时：: {time.time() - old_time}')
